package ru.budget.mobile.di

import android.content.Context
import androidx.room.Room
import org.koin.dsl.module
import ru.budget.mobile.data.sources.local.room.BudgetDatabase

val databaseModule = module {

    single {
        Room.databaseBuilder(
            context = get<Context>(),
            klass = BudgetDatabase::class.java,
            name = "database"
        ).fallbackToDestructiveMigration().build()
    }
}